mixin anchor(link, text)
	if link
		a(href="#" + link, name=link) !{text}
	else
		!{text}

div.heading.clearfix
	htag = "h" + level
	#{htag}: +anchor(link, text)

	if level < 3
		a(href="#top").back-to-top
			| Back to Top
